<div class="content">
  <div class="top">
     <h1 class="titles">{{title}}生成基础实体代码</h1>
     <!-- <a [routerLink]="[ '/jpa/codes' ]" routerLinkActive="active">submit</a> -->
     <form nz-form [formGroup]="validateForm" (ngSubmit)="submitForm()">
      <nz-form-item>
        <nz-form-label [nzSpan]="7" nzRequired>DDL</nz-form-label>
        <nz-form-control [nzSpan]="12" nzHasFeedback [nzErrorTip]="dllErrorTpl">
          <textarea formControlName="sql" nz-input rows="20" placeholder="建表语句"></textarea>
          <ng-template #dllErrorTpl let-control>
            <ng-container *ngIf="control.hasError('sql')">请输入 DDL  语句!</ng-container>
            <ng-container *ngIf="control.hasError('required')">请输入 DDL  语句!</ng-container>
          </ng-template>
        </nz-form-control>
      </nz-form-item>
      <nz-form-item>
        <nz-form-label [nzSpan]="7">Table前缀</nz-form-label>
        <nz-form-control [nzSpan]="12">
          <input nz-input formControlName="ignorePrefix" placeholder="tb_" />
        </nz-form-control>
      </nz-form-item>
      <nz-form-item>
        <nz-form-label [nzSpan]="7">作    者</nz-form-label>
        <nz-form-control [nzSpan]="12">
          <input nz-input formControlName="authorName" placeholder="tn" />
        </nz-form-control>
      </nz-form-item>
      <nz-form-item>
        <nz-form-control [nzOffset]="11" [nzSpan]="15">
          <button nz-button nzType="primary" >Submit</button>
          <button nz-button (click)="resetForm($event)">Reset</button>
        </nz-form-control>
      </nz-form-item>
    </form>
  </div>
</div>